from django.db import models

# Create your models here.
# 图书类
class BookInfo(models.Model):
    '''图书模型类'''
    btitle = models.CharField(max_length=20) #图书名称
    bpub_date = models.DateField()# 出版日期
    bread = models.IntegerField(default=0)# 阅读量
    bcomment = models.IntegerField(default=0) #评论量
    idDelete = models.BooleanField(default=False) #删除标记

    class Meta:
        db_table = 'bookinfo'

    # def __str__(self):
    #     # 返回书名
    #     return self.btitle
